package com.command.center.pucms.pucmsgateway.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.util.List;

/**
 * <p>
 * 用户信息表
 * </p>
 *
 * @author zlb
 * @since 2021-04-23
 */
@Data
@TableName("pucms_t_user_info")
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "用户id")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private Integer id;

    @ApiModelProperty(value = "组织机构表主键")
    private String orgId;

    @ApiModelProperty(value = "用户名称")
    private String name;

    @ApiModelProperty(value = "密码", hidden = true)
    @JsonIgnore
    private String password;

    /**
     * 用户所属角色集合
     */
    @TableField(exist = false)
    private List<Role> roles;
}
